<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Order</title>
<%@page import="java.util.ArrayList"%>
<link href="css/bootstrap.min.css" rel="stylesheet">
<link href="css/dopstyle.css" rel="stylesheet">
</head>
<body class="bg">
<%String  flightNo = request.getParameter("id_flight");
   //int count =(int) request.getAttribute("count");
   String ticketsType = new String( request.getParameter("type").getBytes("ISO-8859-1"),"UTF-8");
   int total = (Integer) request.getAttribute("total");
   String[] tmp =(String[]) request.getAttribute("clientsID");
   ArrayList<Integer> IDs = new ArrayList<Integer>();
   for(int i=0 ;i<tmp.length;i++)
   IDs.add(Integer.parseInt(tmp[i]));
   %>
<div class="header"></div>   
<div class="container">
	<div class="jumbotron">

 
<form method="get" action = "/NCProjectWeb/AddOrder">
			<p>Вы сделали заказ на рейс <%=flightNo %>, для <%=IDs.size() %> человек</p>
			<p>Тип билетов - <%=ticketsType%> </p>
			<hr>
			<p>Итого: <%=total%> </p>
			<hr>
			<%for(int i = 0; i<IDs.size();i++) 
			{
			%>
				<input type="hidden" name ="id" value=" <%=IDs.get(i) %> ">
			<%}%>
				<input type="hidden" name ="ticketType" value=" <%=ticketsType %>">
					<input type="hidden" name ="flightNo" value=" <%=flightNo %> ">
	
				<button type="submit " class="btn btn-primary">Оформить заказ</button>
			
</form>
</div>
</div>
</body>
</html>